/****************************************************************
*  COPYRIGHT MorningCore CO.,LTD                               *
*****************************************************************/
/****************************************************************
 * FileName:    <FFT_fix.h>
 * version:     <1.0.0>
 * Purpose:     <Header file of FFT_fix.c>
 * Authors:     <guohuayong>
 * Notes:       <None>
 ****************************************************************/

/******************************************************************************
*  HISTORY OF CHANGES
*   <Date>          <Author>        <Version>       <DESCRIPTION>
*  2009-06-15      guohuayong        1.0.0            original
*  2018-02-09      lijianfeng        1.0.0            modify

******************************************************************************/\
/*-----------including external files -----------------------------*/
#include <stdlib.h>
#include <math.h>
#include <stdio.h>
#include "../../../../CommLib_FxpC/lib_arith_N.h"
#include "../../../../CommLib_FxpC/FFT_Coef_LookUp.h"

#ifdef __cplusplus
extern "C" {
#endif

//#define _CRT_SECURE_NO_DEPRECATE
/*-----------external variable declaration-------------------------*/

/*-----------constant and type declaration-------------------------*/

/*-----------macro declaration-------------------------------------*/

/*-----------variable declaration-----------------------------------*/

/*-----------Function or task prototype declaration-----------------*/
void FFT_BitReordering_fix_ul(cmplx_frN MidData[], uint16 FFT_Len); //add,zhangyong@2011-01-07,CRID:Enh00000063

void FFT_16_fix_ul(cmplx_frN FFT_Data[], uint16 FFT_16_Len, uint16 FFT_16_Shift); //add,zhangyong@2011-01-07,CRID:Enh00000063

void FFT_8_fix_ul(cmplx_frN FFT_Data[], uint16 FFT_8_Len, uint16 FFT_8_Shift); //add,zhangyong@2011-01-07,CRID:Enh00000063

void FFT_4_fix_ul(cmplx_frN FFT_Data[], uint16 FFT_4_Len, uint16 FFT_4_Shift); //add,zhangyong@2011-01-07,CRID:Enh00000063

void FFT_2_fix_ul(cmplx_frN FFT_Data[], uint16 FFT_2_Len, uint16 FFT_2_Shift); //add,zhangyong@2011-01-07,CRID:Enh00000063

void FFT_3_fix_ul(cmplx_frN FFT_Data[2048], uint16 FFT_3_Len, uint16 FFT_3_Shift); //add,zhangyong@2011-01-07,CRID:Enh00000063

int FFT_Radix_2n_fix_ul(cmplx_frN FFT_Data[2048],
                        uint16 FFT_Len,
                        uint16 FFT_Shift,
                        uint8 Radix16_Num,
                        uint8 Radix8_Num,
                        uint8 Radix4_Num,
                        uint8 Radix2_Num);

int FFT_Radix_2n_fix_ul(cmplx_frN FFT_Data[],
                        uint16 FFT_Len,
                        uint16 FFT_Shift,
                        uint8 Radix16_Num,
                        uint8 Radix8_Num,
                        uint8 Radix4_Num,
                        uint8 Radix2_Num);

uint8 FFT_Radix_1536_fix_ul(cmplx_frN FFT_Data[],
                            uint16 FFT_Len,
                            uint16 FFT_Shift,
                            uint8 Radix16_Num,
                            uint8 Radix8_Num,
                            uint8 Radix4_Num,
                            uint8 Radix2_Num);
uint8 FFT_2n_1536_fix_ul(cmplx_frN FFT_Data[], uint16 FFT_Len, uint16 FFT_Shift);

void cmplx_frN_mult_fract40_ul(fract40 *outRe, fract40 *outIm, cmplx_frN a, cmplx_frN b);

cmplx_frN cmplx_frN_mult_fract40_frN_ul(cmplx_frN a, cmplx_frN b, uint16 shift);

cmplx_frN FFT_Coef_fix_ul(uint16 k);

void fileprintf(cmplx_frN *FFT_Temp, cmplx_frN *twidle_temp, cmplx_frN *FFTData, int FFT_Len, int m);

#ifdef __cplusplus
}
#endif







